import request from '@/utils/request';

// 查询列表
export async function queryPageList(params) {
  return request('/b/dbinfo/queryPageList', {
    method: 'POST',
    data: params,
  });
}

export async function scan(params) {
  return request('/b/dbscanresult/scan', {
    method: 'POST',
    data: params,
  });
}

export async function add(params) {
  return request('/b/dbinfo/add', {
    method: 'POST',
    data: params,
  });
}

export async function update(params) {
  return request('/b/dbinfo/update', {
    method: 'POST',
    data: params,
  });
}
export async function dbinfodelete(params) {
  return request('/b/dbinfo/delete', {
    method: 'POST',
    data: params,
  });
}

export async function testConnection(params) {
  return request('/b/dbinfo/testConnection', {
    method: 'POST',
    data: params,
  });
}

export async function updateLevel(params) {
  return request('/b/dbscanresult/updateTypeAndLevel', {
    method: 'POST',
    data: params,
  });
}

export async function queryListByTypeCode(params) {
  return request('/s/datadict/queryListByTypeCode', {
    method: 'POST',
    data: params,
  });
}